package com.ruoyi.business.enums;

//发送者详情枚举
public enum SendInfoEnum {
    AREA(101, "屈场路"), //乡镇/街道
    ZIP(102, "0"), //邮编
    ADDRESS(103, "湖北省荆门市京山市屈场路领工防护装备有限公司"), //详细地址
    AREACODE(104, "0"), //发货人所在乡镇/街道编码
    COUNTYCODE(105, "0"),//发货人所在区/县编码
    CITYCODE(106, "0"),//发货人所在城市编码
    PROVINCECODE(107, "0"),//发货人所在省份编码
    PROVINCE(108, "湖北省"), //省份
    CITY(109, "荆门市"), //城市
    LATITUDE(110, "0"), //维度
    COUNTY(111, "京山市"),//城市
    LONGITUDE(112, "0"), //经度
    SENDERADDRESS(113, "湖北省荆门市京山市屈场路领工防护装备有限公司"), //发货人完整地址信息
    SENDERNAME(114, "邓敏"), //发货人名称
    SENDERMOBILE(115, "15827876803"), //发货人电话
    PROCESSVID(116, " 6017037364631"),//操作门店的组织 ID
    PROCESSVIDNAME(117, "驰选MRO"),//我的品牌
    ORDERSTATUS(118, "5"); //订单状态，5-已发货
    private final int code;
    private final String message;


    SendInfoEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return message;
    }

    // 通过code查找枚举
    public static SendInfoEnum fromCode(int code) {
        for (SendInfoEnum status : values()) {
            if (status.code == code) {
                return status;
            }
        }
        throw new IllegalArgumentException("未知状态码: " + code);
    }
}
